package com.yqg.education.mapper;

import com.yqg.education.entity.Live;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author 张芸博
 * @since 2025-04-10
 */
@Mapper
public interface LiveMapper extends BaseMapper<Live> {

    List<Live> findPage(Integer pageNum, Integer pageSize, Integer courseId, Integer teachId, Integer flow);

    Long findCount(Integer courseId, Integer teachId, Integer flow);

    List<Live> findStuPage(@Param("pageStartNumber") Integer pageStartNumber,
                           @Param("pageSize") Integer pageSize,
                           @Param("name") String name,
                           @Param("typeId") Integer typeId,
                           @Param("courseIds") List<Long> courseIds,
                           @Param("courseId") Integer courseId);

    Long findStuCount(@Param("name") String name,
                      @Param("typeId") Integer typeId,
                      @Param("courseIds") List<Long> courseIds,
                      @Param("courseId") Integer courseId);

    Long getInfoCount(@Param("flow") Integer flow);
}
